import { commonOption } from 'api/config'
import axios from 'axios'

export function modeGet(param) {
	const url = commonOption.host + '/modeGet'
	const params = Object.assign({}, param)
	return axios.get(url, {
        params: params
    })
}

export function modePost (path, param) {
  const url = commonOption.host + path
  let formData = new FormData()
  for (let key in param) {
    formData.append(key, param[key])
  }
  return axios.post(url, formData)
}
